<html>
	<head>
		<style type="text/css">
		h3 { font-family: Arial,sans-serif; color:#000; margin-left:10px; 
		    font-weidth: bold;}
		h4 { font-family: Arial,sans-serif; color:#000; margin-left:10px; 
		    font-weidth: bold;}
		#menubar{width:1000;}
        #menubar ul { margin:20px; padding:0px; list-style:none; text-align:center; border:1px solid #000;  }
        #menubar ul li{padding:0 25px 0 25px; }
        #menubar ul li a {text-decoration:none; font:20px/35px Arial,sans-serif;height:102px; color: Gray; font-weight: bold; }
		</style>
	</head>
	
	<body><title>Stock Quote Program </title>
	
	 
	<table width="1000" bgcolor=#FFF cellspacing="0" cellpadding="0" style="padding-top:0px; padding-bottom:400px;">
<tr>
    <td >
        <div id="menubar">
        <ul>
            <li><h3> Welcome to Stock Quote Program</h3></li>
            

<li><SCRIPT TYPE="text/javascript">
<!--
function dropdown(mySel)
{
var myWin, myVal;
myVal = mySel.options[mySel.selectedIndex].value;
if(myVal)
   {
   if(mySel.form.target)myWin = parent[mySel.form.target];
   else myWin = window;
   if (! myWin) return true;
   myWin.location = myVal;
   }
return false;
}
//-->
</SCRIPT>
<br>
<br>

<FORM 
     ACTION="../cgi-bin/redirect.pl" 
     METHOD=POST onSubmit="return dropdown(this.gourl)">
<SELECT NAME="gourl">
<OPTION VALUE="">Select Stock...

<OPTION VALUE="Yahoo.html">YAHOO
<OPTION VALUE="Google.html">GOOG
<OPTION VALUE="Dell.html">DELL
<OPTION VALUE="Nokia.html"> NOK
<OPTION VALUE="MSFT.html">MSFT
<OPTION VALUE="Nor.html">NOR 


</SELECT>


<INPUT TYPE=SUBMIT VALUE="Go">
<br>
<br>
</FORM>
    <script src="http://code.jquery.com/jquery-latest.js"></script>
    <script>
      $(document).ready(function(){  
        $.getJSON("http://mdbitz.com/testing/PHPYahooFinance/finance.php?symbol=NOK&callback=?",
          function(data){
            $("#symbol").text( data.symbol );
            $("#previousClose" ).text( data.previousClose );
            $("#open" ).text( data.open );
            $("#lastTrade").text( data.lastTrade );
            $("#lastTradeTime").text( data.lastTradeTime );
            $("#change").text( data.change );
            $("#daysLow").text( data.daysLow );
            $("#daysHigh").text( data.daysHigh );
            $("#volume").text( data.volume);
          }
        );
     });
     </script>
	 
</head>
  <body>
    <div id="quote">
      <table cellspacing="0" cellpadding="3" border="1">
        <tr>
          <th>Symbol</th>
          <th>Last Trade</th>
          <th>Last Trade Time</th>
          <th>Change</th>
          <th>Open</th>
          <th>Previous Close</th>
          <th>Day's Low</th>
          <th>Day's High</th>
          <th>Volume</th>
        </tr>
        <tr>
          <td id="symbol"></td>
          <td id="lastTrade"></td>
          <td id="lastTradeTime"></td>
          <td id="change"></td>
          <td id="open"></td>
          <td id="previousClose"></td>
          <td id="daysLow"></td>
          <td id="daysHigh"></td>
          <td id="volume"></td>
        </tr>
      </table>
    <br>
	<!-- Start of Yahoo! Finance code -->
<center><iframe allowtransparency="true" marginwidth="0" marginheight="0" hspace="0" vspace="0" 
frameborder="0" scrolling="no" src="http://api.finance.yahoo.com/instrument/1.0/NOK/badge;chart=6m;quote/HTML?AppID=86hE_EQfjHXluKiguh0TWct2S.24&sig=taNiU8cKa.uZ7R5PXlsa2IJbDgw-&t=1335873688663" width="300px" height="400px"><a href="http://finance.yahoo.com">Yahoo! Finance</a><br/><a href="http://finance.yahoo.com/q?s=NOK/">Quote for NOK/</a></iframe>
<!-- End of Yahoo! Finance code -->
	  <br>
	 Calculate your stocks
	  <br>
	  <br>
	 <script type="text/javascript">

function Add()
{
   document.getElementById("Output").value =
   document.getElementById("FirstNo").value *
   document.getElementById("SecondNo").value;
}

</script>
last Trade:<input id="FirstNo" type="text" value="" style="width:50px"/>
Stocks number:<input id="SecondNo" type="text" value="" style="width:50px"/>
<input type="button" value=" = " onclick="Add()"/>
<input id="Output" type="text" style="width:50px"/>
  </li>
        </ul>
    </div>
</td>
</tr>
</table>
<br>
			
			<br>
			
		</form>
	</body>
</head>
